import { WeaTools } from 'ecCom';

export const getSellChanceList = params => // 获取商机列表
  WeaTools.callApi('/api/crm/sellchance/list', 'GET', params);


export const getSellChanceCondition = params => // 获取商机高级搜索
  WeaTools.callApi('/api/crm/sellchance/condition', 'GET', params);


export const getSellChanceTab = params => // 获取商机tab
  WeaTools.callApi('/api/crm/sellchance/tabs', 'GET', params);


export const getSellChanceStatusAndHrm = params => // 获取商机选择框
  WeaTools.callApi('/api/crm/sellchance/conditionTop', 'GET', params);


export const getProductInfo = params => // 产品，。，根据产品id获取产品信息。，明细表联动
  WeaTools.callApi('/api/crm/product/productInfo', 'GET', params);


export const getSellChanceDetail = params => // 商机名称 获取右侧详情
  WeaTools.callApi('/api/crm/sellchance/rightInfo', 'GET', params);


// export const deleteSellChance = params => {   //商机   --删除
//     return WeaTools.callApi('/api/crm/sellchance/delete', 'POST', params);
// }


export const getRemindInfo = params => // 商机  相关交流联系提醒
  WeaTools.callApi('/api/crm/contactLog/remindInfo', 'GET', params);


// export const saveRemindSet =params =>{ //商机  相关交流联系提醒  保存
//     return WeaTools.callApi('/api/crm/contactLog/remindSetting', 'GET', params);
// }

/** *s客户卡片商机列表接口 */
export const getChanceList = requestParams => WeaTools.callApi('/api/crm/sellchance/listOfCustomer', 'GET', requestParams);

export const getChanceForm = requestParams => WeaTools.callApi('/api/crm/sellchance/form', 'GET', requestParams);

export const chanceFormSave = requestParams => WeaTools.callApi('/api/crm/sellchance/formSave', 'POST', requestParams);

export const chanceFormUpdate = requestParams => WeaTools.callApi('/api/crm/sellchance/formUpdate', 'POST', requestParams);

export const chanceDelete = requestParams => WeaTools.callApi('/api/crm/sellchance/delete', 'POST', requestParams);
export const getShareForm = requestParams => WeaTools.callApi('/api/crm/sellchance/auth/getCreaterAuthorFormCondition', 'GET', requestParams);
export const saveSellChanceAuth = requestParams => WeaTools.callApi('/api/crm/sellchance/auth/saveSellChanceAuth', 'GET', requestParams);
export const getShareList = requestParams => WeaTools.callApi('/api/crm/sellchance/auth/getSellChanceAuthorList', 'GET', requestParams);
export const deleteSellChanceAuths = requestParams => WeaTools.callApi('/api/crm/sellchance/auth/deleteSellChanceAuths', 'GET', requestParams);
export const getSellChanceTabs = requestParams => WeaTools.callApi('/api/crm/sellchance/getSellChanceTabs', 'GET', requestParams);
